
import lc = module("utils/commons/Locale");
	
/**
	* Supports the representation of a description in one locale.
	* Multiple language versions of a specific description are grouped together 
	* in an InternationalString.
	* 
	* @author Xavier Sosnovsky, Anthony Morel
	* 
	* @see LocalisedStringsCollection
	*/
export class LocalisedString {
		
	/*==============================Fields================================*/
		
	private _label:string;
		
	private _locale:lc.Locale;
		
	/*===========================Constructor==============================*/
		
		/**
	    * Creates a new LocalisedString instance, taking a locale and a
	    * language specific representation of a description as parameters.
	    * 
	    * @param locale The locale of the string (e.g: en).
	    * @param label The language specific representation of a description
	    * (e.g.: Statistics) 
	    */
	constructor(locale:lc.Locale, label:string) {
		this._label = label;
		this._locale = locale;
	}
		
	/*============================Accessors===============================*/
		
	/**
	    * The language-specific text
	    */
	public getLabel():string {
        return this._label;
	}
		
	/**
	    * @private
	    */
	public setLabel(label:string) {
        this._label = label;
	}
		
	/**
	    * The locale of the current LocalisedString instance
	    */
	public getLocale():lc.Locale {
        return this._locale;
	}
		
	/**
	    * @private
	    */
	public setLocale(locale:lc.Locale) {
        this._locale = locale;
	}		
}